package com.jic.market.service;

import com.jic.common.base.vo.RestResult;
import com.jic.market.entity.PatchGrouponInstEntity;
import com.jic.market.orm.Pagination;
import com.jic.market.request.PatchGrouponInstRequest;
import com.jic.market.request.manager.patchgroup.PatchGrouponInstForceGroupRequest;
import com.jic.market.response.PageResponse;
import com.jic.market.response.PatchGrouponInstResponse;
import com.jic.market.response.manager.patchgroup.PatchGrouponInstForceGroupResponse;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author guohuayong
 * @date: 2020年01月20日
 */
public interface PatchGrouponInstService {
    PageResponse<PatchGrouponInstResponse> query(PatchGrouponInstRequest t);

    PatchGrouponInstResponse detail(PatchGrouponInstRequest t);

    /**
     * 强制成团
     * @param request
     * @return
     */
    PatchGrouponInstForceGroupResponse forceGroup(PatchGrouponInstForceGroupRequest request);

    /**
     * 增加实例记录
     * @param instEntity
     * @return
     */
    Integer addInstEntity(PatchGrouponInstEntity instEntity);

    /**
     * 查询拼团实例
     * @param instEntity
     * @return
     */
    PatchGrouponInstEntity queryEntity(PatchGrouponInstEntity instEntity);

    /**
     * 更新拼团实例信息
     * @param instEntity
     * @return
     */
    Integer update(PatchGrouponInstEntity instEntity);

    /**
     * 查询列表
     * @param instEntity
     * @param page
     * @return
     */
    List<PatchGrouponInstEntity> findOfPage(PatchGrouponInstEntity instEntity, Pagination page);

    /**
     * 查询总数
     * @param instEntity
     * @return
     */
    Integer countOfPage(PatchGrouponInstEntity instEntity);
}
